<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml">>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Together</title>
</head>
<body>
	<%@include file="header.jsp"%>
	<!--  http://greenchiou.blogspot.com/2010/12/javascript-facebook-sdk-width-graphic.html -->
	<div class="container">
		<div id="fb-root"></div>
		<script>
        window.fbAsyncInit = function() {
          FB.init({
            appId      : '119388268186376',
            status     : true, 
            cookie     : true,
            xfbml      : true,
            oauth      : true,
          });
          /*
          FB.getLoginStatus(function(response) {
              if (response.session) {
                  alert(response.session);
              }
          })
        //retrieve personal information
          FB.api('/me', function(user) {
              if (user) {
                var image = document.getElementById('image');
                image.src = 'https://graph.facebook.com/' + user.id + '/picture';
                var name = document.getElementById('name');
                name.innerHTML = user.name
              }
            });
          */
        };
        (function(d){
           var js, id = 'facebook-jssdk'; if (d.getElementById(id)) {return;}
           js = d.createElement('script'); js.id = id; js.async = true;
           js.src = "//connect.facebook.net/en_US/all.js";
           d.getElementsByTagName('head')[0].appendChild(js);
         }(document));
		
        
        
      </script>
		<div class="fb-login-button" data-scope="email,user_checkins">Login
			with Facebook</div>
		<div>
		<!-- 
		<fb:login-button autologoutlink="true" perms="email,user_birthday,status_update,publish_stream"></fb:login-button>
			<img id="image" />
			<div id="name"></div>
		 -->
		</div>
		 2317
	</div>
	<a href="https://www.facebook.com/dialog/oauth?client_id=119388268186376&redirect_uri=https://www.facebook.com/apps/application.php?id=119388268186376&scope=email&state=SOME_ARBITRARY_BUT_UNIQUE_STRING">Login by server</a>
</body>
</html>